from django.conf.urls.defaults import *

urlpatterns = patterns('ytcommunity.forum.view',
    (r'^$', 'board.list', {'template':'forum/boards.html'}),
    (r'^board/(?P<name>\w+)/$', 'board.display', {'template':'forum/board_display.html'}),
    (r'^board/(?P<name>\w+)/add/$', 'post.add', {'template':'forum/add.html'}),
    (r'^all/$', 'post.all', {'template':'forum/all.html'}),
    (r'^post/(?P<id>\d+)/$', 'post.display', {'template':'forum/display.html'}),
    (r'^post/edit/(?P<id>\d+)/$', 'post.edit', {'template':'forum/edit.html'}),
    (r'^post/delete/(?P<id>\d+)/$', 'post.delete'),
    (r'^post/stick/(?P<id>\d+)/$', 'post.stick'),
    (r'^post/unstick/(?P<id>\d+)/$', 'post.unstick'),
    (r'^post/comment/(?P<id>\d+)/$', 'comment.add'),                    
    (r'^post/comment/delete/(?P<id>\d+)/$', 'comment.delete'),                    

    (r'^feed/(?P<name>\w+)/$', 'post.feed'),
    (r'^feed/$', 'post.feed'),

    (r'^api/query/$', 'post.query_api'),

    (r'^admin/board/add/$', 'board.add', {'template':'forum/board_add.html'}),                    
    (r'^admin/board/edit/(?P<name>\w+)/$', 'board.edit', {'template':'forum/board_edit.html'}),                    
)
